import request from '@/utils/request'

// 查询配件订单列表
export function listOrder(query) {
  return request({
    url: '/system/accessoriesorder/list',
    method: 'get',
    params: query
  })
}

// 查询配件订单详细
export function getOrder(accessoriesOrderId) {
  return request({
    url: '/system/accessoriesorder/' + accessoriesOrderId,
    method: 'get'
  })
}

// 新增配件订单
export function addOrder(data) {
  return request({
    url: '/system/accessoriesorder',
    method: 'post',
    data: data
  })
}

// 修改配件订单
export function updateOrder(data) {
  return request({
    url: '/system/accessoriesorder',
    method: 'put',
    data: data
  })
}

// 删除配件订单
export function delOrder(accessoriesOrderId) {
  return request({
    url: '/system/accessoriesorder/' + accessoriesOrderId,
    method: 'delete'
  })
}

// 导出配件订单
export function exportOrder(query) {
  return request({
    url: '/system/accessoriesorder/export',
    method: 'get',
    params: query
  })
}